import Vue from 'vue'
import Router from 'vue-router'
import Hello from '@/components/Hello'
import Index from '../views/Index'
import Home from '../views/Home.vue'
import Video from '../views/Video.vue'
import Living from '../views/Living.vue'
import Periodical from '../views/Periodical.vue'
import Me from '../views/Me.vue'
import VideoDetail from '../views/VideoDetail.vue'

Vue.use(Router)

export default new Router({
  routes: [
    {
    path: '/',
    name: 'Index',
    redirect: '/home',
    component: Index,
    children: [{
        path: 'home',
        name: 'home',
        component: Home,
      },
      {
        path: 'video',
        name: 'video',
        component: Video,
      },
      {
        path: 'living',
        name: 'living',
        component: Living,
      },
      {
        path: 'periodical',
        name: 'periodical',
        component: Periodical,
      },
      {
        path: 'me',
        name: 'me',
        component: Me,
      }

    ]
  },
  {
    path: '/videoDetail',
    name: 'videoDetail',
    component: VideoDetail
  }
  ]
})
